package com.school.sports.controller;

import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.HashMap;
import java.util.Map;

@RestController
@RequestMapping("/api/login")
public class TestController {

    @GetMapping
    public ResponseEntity<Map<String, Object>> testConnection() {
        Map<String, Object> response = new HashMap<>();
        response.put("success", true);
        response.put("message", "后端连接成功！");
        response.put("timestamp", new java.util.Date());
        response.put("data", "测试数据");


        System.out.println("aaaa");



        return ResponseEntity.ok(response);
    }
}
